]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
windowManager: Keep dim effect in overview
authorFlorian Müllner <fmuellner@gnome.org>
Mon, 29 Jan 2024 20:12:44 +0000 (21:12 +0100)
committerFlorian Müllner <fmuellner@gnome.org>
Mon, 29 Jan 2024 20:28:56 +0000 (21:28 +0100)
Removing the effect dates back to the time when we didn't show
attached dialogs in the overview. Since we do show attached
dialogs as such nowadays, it makes sense to keep the effect.

Close https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6265

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3151>

js/ui/windowManager.js

index 7603a8ed0ce1d9b14f391c10852ac731af3e7861..d85e1e09488c48dd06eb6897e1a669d7922a6375 100644 (file)
@@ -512,8 +512,6 @@ export class WindowManager {
         this._resizePending = new Set();
         this._destroying = new Set();
 
-        this._dimmedWindows = [];
-
         this._skippedActors = new Set();
 
         this._allowedKeybindings = {};
@@ -930,15 +928,6 @@ export class WindowManager {
             IBusManager.getIBusManager().restartDaemon();
         });
 
-        Main.overview.connect('showing', () => {
-            for (let i = 0; i < this._dimmedWindows.length; i++)
-                this._undimWindow(this._dimmedWindows[i]);
-        });
-        Main.overview.connect('hiding', () => {
-            for (let i = 0; i < this._dimmedWindows.length; i++)
-                this._dimWindow(this._dimmedWindows[i]);
-        });
-
         this._windowMenuManager = new WindowMenu.WindowMenuManager();
 
         if (Main.sessionMode.hasWorkspaces)
@@ -1426,12 +1415,9 @@ export class WindowManager {
 
         if (shouldDim && !window._dimmed) {
             window._dimmed = true;
-            this._dimmedWindows.push(window);
             this._dimWindow(window);
         } else if (!shouldDim && window._dimmed) {
             window._dimmed = false;
-            this._dimmedWindows =
-                this._dimmedWindows.filter(win => win !== window);
             this._undimWindow(window);
         }
     }
@@ -1560,10 +1546,6 @@ export class WindowManager {
     _destroyWindow(shellwm, actor) {
         let window = actor.meta_window;
         window.disconnectObject(actor);
-        if (window._dimmed) {
-            this._dimmedWindows =
-                this._dimmedWindows.filter(win => win !== window);
-        }
 
         if (window.is_attached_dialog())
             this._checkDimming(window.get_transient_for());